import axios from "@/http/http.js";
// 封装添加预约信息接口
export const addAppointmentAPI = (data) => {
    return axios({
        url: '/appointment/addAppointment',
        method: 'post',
        data
    })
};

// 封装获取预约状态接口
export const appointmentStatusFindAPI = (data) => {
    return axios({
        url: '/appointment/findAppointmentStatus',
        method: 'post',
        data
    })
};

// 封装取消预约接口
// export const cancelAppointmentAPI = (data) => {
//     return axios({
//         url: '/appointment/cancelAppointment',
//         method: 'put',
//         data
//     })
// };

// 封装获取预约记录接口
export const appointmentRecordsFindAPI = (data) => {
    return axios({
        url: '/appointment/findAppointmentRecords',
        method: 'post',
        data
    })
};


// 封装取消预约并退款接口
export const cancelAppointmentAPI = (params) => {
    return axios({
        url: '/alipay/refund',
        method: 'get',
        params
    })
};